package com.parkclouds.busi.biz.sys;

import com.parkclouds.api.commom.bean.BizResult;
import com.parkclouds.api.commom.service.sys.SysOpService;
import com.parkclouds.api.commom.service.sys.dto.SysOpDTO;
import com.parkclouds.api.commom.service.sys.param.QuerySysOpReq;
import com.parkclouds.busi.dao.SysOpDao;
import com.parkclouds.busi.domain.SysOp;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * Copyright: Copyright (c) 2017  zteits
 *
 * @ClassName: SysOpServiceImpl.java
 * @Description:
 * @version: v1.0.0
 * @author: wangfs
 * @date: 2019-04-23 16:59
 * Modification History:
 * Date             Author          Version            Description
 * ---------------------------------------------------------*
 * 2019-04-23     wangfs              v1.0.0               创建
 */
@Service("com.parkclouds.busi.biz.sys.SysOpServiceImpl")
public class SysOpServiceImpl implements SysOpService {

    @Autowired
    private SysOpDao sysOpDao;

    @Override
    public BizResult<SysOpDTO> querySysOp(QuerySysOpReq req) {
        SysOpDTO sysOpDTO = new SysOpDTO();
        SysOp sysOp = sysOpDao.querySysOp(req);
        if(null != sysOp){
            BeanUtils.copyProperties(sysOp,sysOpDTO);
        }
        return new BizResult<SysOpDTO>(sysOpDTO);
    }
}
